package com.shujia.properties;

import java.io.FileInputStream;
import java.util.Properties;

public class DemoProperties {
    public static void main(String[] args) throws Exception {

        //创建properties解析文件对象
        Properties properties = new Properties();

        //加载配置文件
        properties.load(new FileInputStream("java/data/config.properties"));

        //通过key获取value

        String studentPath = properties.getProperty("student.path");

        System.out.println(studentPath);

        String scorePath = properties.getProperty("score.path");

        System.out.println(scorePath);


    }
}
